package com.example.demo.vo;

import lombok.Data;

@Data
public class R {

    private  int code;
    private  String msg;
    private  Object data;

    public static  R ok (Object data){
        R r=new R();
        r.setCode(0);
        r.setData(data);
        r.setMsg("success");
        return r;
    }
    public  static  R ERROR (String msg){
        R  r=new R();
        r.setCode(1);
        r.setMsg(msg);
        return  r;
    }
}
